Method of the image processing

ABSTRACT

A method of image processing for sampling the concentration of each portion of an image in the unit of a picture element and for binarizing the concentrations of picture elements in the unit of a submatrix of predetermined size to obtain a bi-level image, being characterized in that the bi-level image is obtained from the concentrations having been sampled according to the steps as follows: (a) calculating the average of the concentrations of the picture elements at every submatrix to which the picture elements belong; (b) determining the number of elements in the submatrix to be treated as either one of black and white according to a predetermined relation with the average; (c) assigning elements in the submatrix as the elements to be treated as either one of black and white up to the number determined in the step (b) in the predetermined order of the concentration of each element.

BACKGROUND OF THE INVENTION

1. Field of the Invention

The present invention relates to a method apparatus of image processingwherein an image, such as a copier image, including at least onehalf-tone portion is reproduced by bi-level quantization.

2. Description of the Prior Art

When an image is reproduced with bi-level quantization of black andwhite, a half-tone image will also be reproduced as a bi-level image.The resolution and the tone (or the reproduction of concentration) areimportant factors in the image processing. The resolution is importantespecially for line images such as a character, a symbol and the like,whereas the tone is important for half-tone images such as a picture ofa face. Because the resolution and the tone counteract to each other,various kinds of image processing methods in apparatus have beendeveloped in order to make both factors compatible. The compatibility isespecially needed for an image wherein both a line image and a toneimage are mixed.

The systematic dither processing is effective for reproduction of ahalf-tone image. In this processing, the concentration signals of animage sampled by a scan of picture elements of N×M matrix are dividedinto P×P submatrices, and the concentration signals of each submatrixare binarized with predetermined threshold values of P×P matrix of adither pattern (see, for example, FIG. 1).

An example of image processing of the systematic dither processing willbe explained below: First, assume that such a line image 1 as shown inFIG. 2 is detected by sixteen picture elements which constitute a 4×4submatrix. Each of the numerical values given to each of the elements ofa submatrix shown in FIG. 3 represents the concentration of the lineimage at each corresponding picture elements of the submatrix shown inFIG. 2. When a matrix of the Bayer type shown in FIG. 1 is employed as adither pattern, the numerical value of each element shown in FIG. 3 iscompared with that of the counter element of the Bayer type dithermatrix which gives a threshold level of each picture element. Theelement in the submatrix where the concentration is larger than thethreshold is binarized as black. FIG. 4 shows a bi-level image thusreproduced.

In a second example, such a half-tone image 2 as shown in FIG. 5schematically is processed similarly. Each of the numerical values givento each of the elements of a submatrix shown in FIG. 6 represents theconcentration of the corresponding picture element of the submatrixshown in FIG. 5. According to the image processing by using a dithermatrix of the Bayer type shown in FIG. 1, the half-tone image 2 of FIG.5 is reproduced as a bi-level image as is shown in FIG. 7.

As mentioned above, in the systematic dither processing, theconcentration signal of each picture element in a matrix ofN(/mm)×M(/mm) picture elements are processed in the unit of P×Psubmatrix. If P increases, N/P and M/P decreases, and the resolutionbecomes lower. On the contrary, if P decreases or if the submatrixbecomes small, the tone is deteriorated. Thus, it is difficult toreproduce a half-tone image having a satisfactory quality in respect toboth resolution and tone.

For example, an image including a half-tone portion is sampled withpicture elements of 8(/mm)×8(/mm) matrix, and the image is reproducedwith black and white picture elements of 8(/mm)×8(/mm) matrix as aresult of the dither processing. If a dither pattern of 2×2 matrix isused, the size of each picture element of the image to be reproduceddoes not become large so that the resolution is not significantlylowered largely while the image cannot be reproduced to provide a toneof high quality. On the contrary, if a dither pattern of 4×4 matrix isused, although the tone is improved, the resolution o the image islowered so that the quality of the reproduced image becomes worse.

In the JPN. Pat. laid open publication No. 138969/1980, a process isdisclosed wherein the concentration level of a picture element underconsideration is estimated by taking those of the element picturessurrounding the picture element into account in order to determine thebi-level of each surrounding picture elements. This processing methodcorresponds substantially to a dither processing with a finer ditherpattern. Accordingly, it can not essentially improve the resolution of aline image.

SUMMARY OF THE INVENTION

A purpose of the present invention is to provide a method of imageprocessing wherein a line image can be reproduced without lowering theresolution thereof while an image, including at least one portion ofhalf-tone image can be reproduced with a high resolution and in anexcellent tone.

According to the present invention, there is provided a method of imageprocessing for sampling the concentration of each portion of an image inthe unit of a picture element and for binarizing the concentrations ofpicture elements in the unit of a submatrix of a predetermined size toobtain a bi-level image, being characterized in that the bi-level imageobtained from the concentrations have been sampled according to thesteps as follows:

(a) calculating the average of the concentrations of the pictureelements at every submatrix to which the picture elements belong;

(b) determining the number of elements in the submatrix to be treated asblack or white according to predetermined relationship with the average;

(c) assigning elements in the submatrix up to the number of elementsdetermined in the step (b) in decreasing or increasing order ofconcentration according as whether black or white dots are to beprinted.

An advantage of the present invention is that an image which includes atleast one half-tone portion can be reproduced by bi-level quantizationwith a high fidelity to the original image without lowering theresolution.

BRIEF EXPLANATION OF THE DRAWINGS

Further objects and advantages of the present invention will be apparentfrom the following description, reference being had to the accompanyingdrawings wherein preferred embodiments of the present invention areclearly shown.

In the drawings:

FIG. 1 is a dither matrix of the Bayer type;

FIG. 2 is a line image;

FIG. 3 is a submatrix of the concentration of the line image shown inFIG. 2;

FIG. 4 is a reproduction of the line image shown in FIG. 2 by a ditherprocess;

FIG. 5 is a half-tone image;

FIG. 6 is a submatrix of the concentration of the half-tone image shownin FIG. 5;

FIG. 7 is a reproduction of the half-tone image shown in FIG. 2 by adither process;

FIG. 8 is a chart which shows processes according to the presentinvention;

FIG. 9 is a block diagram of an image processing apparatus according tothe present invention;

FIG. 10 is a flow chart of a program to be used in the presentinvention;

FIG. 11 is a diagram which shows the of picture elements with numbers;

FIG. 12 is a reproduction of a line image according to an embodiment ofthe present invention; and

FIG. 13 is a reproduction of a half-tone image according to anembodiment of the present invention.

DESCRIPTION OF PREFERRED EMBODIMENTS OF THE INVENTION

Referring to FIG. 8, in a method of image processing according to thepresent invention, (a) the concentrations are sampled in the unit of oneelement at the a step and are binarized in the unit of a submatrix of apredetermined size. In the binarizing process, (b) an averageconcentration in every submatrix is calculated, (c) the dot number inthe submatrix, that is, the number of elements to be assigned as blackor white is determined from the average concentration, and (d) elements(dot positions) in the submatrix are assigned up to the dot number inthe order of concentration.

All elements up to the determined dot number may not be assigned only bythe above-mentioned process. (e) Such a case, wherein the number of therest of the elements that still remain to be assigned is smaller thanthe number of elements having the same concentration, may arise when theconcentration level approaches the average concentration. (f) Then, theelements that still remained to be assigned are assigned successively inthe order of the surrounding concentration which is calculated as a sumor an average of concentrations of the elements surrounding each elementhaving the same concentration. This means substantially that elementswhich are locate near the elements designated already are assignedpriority.

(g) If all elements up to the dot number are not assigned by theabove-mentioned processes, that is, if the number of elements that stillremained to be assigned next are smaller than the number of the elementshaving the same surrounding concentration, (h) the elements the stillremain to be assigned are assigned in the order of a predetermined tablewhich defines the order of the assignment in a submatrix.

Then, (i) the bi-level data obtained by the above-mentioned processesare transmitted to external equipment such as a printer.

FIG. 9 shows a block diagram of an image processing apparatus of themirror-scan type or of the document-scan type wherein an embodiment ofthe present invention is adopted. A concentration signal sampled by animage sensor 11 is quantized by an A/D converter 12, and is stored in amemory 13. A standard oscillator 14 gives a clock signal to the imagesensor 11 and to an address counter 15 which in turn gives an address tothe memory 13. Thus, the memory 13 is synchronized with the image sensor11 on sampling. The memory 13 is connected to a CPU 16. Theconcentration signals once stored in the memory 13 are transformed tobi-level signals, which in turn are transmitted to external equipmentsuch as a printer.

FIG. 10 shows a flow chart of a program stored in the CPU 16 accordingto embodiments of the present invention.

As a first example, the reproduction of a line image 1 shown in FIG. 2will be explained. FIG. 10 deals with a process of determining thepicture elements for black dots. On the other hand, a case ofdetermining white dots can be processed similarly by taking into accounta reverse relation to the concentration.

First, the concentration level signals sampled by the image sensor 11are stored in the memory 13 (step Pl).

After the entire image 1 has been sampled, the concentration levelsignals are processed in the unit of a 4×4 submatrix for bi-levelquantization as follows: A concentration pattern in the unit of a 4×4submatrix shown in FIG. 3, corresponding to the line image 1 shown inFIG. 2, is read out of the memory 13 (step P2). An average concentrationof the concentration pattern is calculated (step P3), and the averageconcentration is found to be (12×4+6×4)/16=4.5. Next, the dot number,that is, the number of elements to be printed as black or white isdetermined from the average concentration (step P4). For example, thedot number is five if it is determined as an integer obtained byrounding off fractions of the average x. (In general, the dot number canbe determined by using an appropriate function f(x) of the average x. Inthis case we use f(x)=x concisely.) In case of a white-dot output wherethe positions of picture elements for white dots are designated, we usef(x)=P×P-x where P is the size of the submatrix.)

Next, the concentration level data are arranged in the order of theconcentration by sorting them (step P5). Here, we indicate the positionsof the picture elements in a submatrix respectively by the numbers shownin FIG. 11, and express the concentration level data with thecombination of the picture element position and the concentration levelthereat. Then, the concentration level data shown in FIG. 3 arerearranged in the decreasing order of concentration, that is, "1"-12,"5"-12, "9"-12, "13"-12, "2"-6, "6"-6, "10"-6, "14"-6, "3"-0, "4"-0,"7"-0, "8"-0, "11"-0, "12"-0, "15"-0 and "16"-0. In case of white-dotoutput the order should be reversed.

Next, black dots of the dot number obtained in step P4 are assigned inthe decreasing order of concentration level. First, the highestconcentration of the picture elements which have not yet been assignedis designated as the concentration level for assignment (step P6). Now,the highest level 12 is designated. (In case of white-dot output, thelowest concentration level is designated.) Next, a check is made todetermine whether the number of the picture elements having the sameconcentration level designated is larger than one (step P7). Fourequivalent positions ("1", "5", "9" and "13") is found to exist at theconcentration level 12. (If the result of the check is "No", the processis skipped to step P12 immediately and the position for black dot isdesignated.) Next, it is also decided whether the number of theremainder (in the present case, five) still remained to be assignedamong the picture elements of the dot number is smaller than that of theelements having the same concentration level (at present, four) (stepP8). Since the decision is "No" in the present example, steps P9-P11 areskipped to step P12, and four equivalent positions ("1", "5", "9" and"13") for black dots are designated in step P12. Then, it is decidedwhether the designation of the dot positions is completed (step P13).Because the decision is "No" in the present case, the process isreturned to step P6, and the next concentration level "6" is designatedtherein. It is found that four equivalent positions ("2", "6", "10" and"14") exist at the same concentration level 6 (step P7). Then, it ischecked whether the remainder of the dot number (in the present case,5-4=1) is smaller than the number of the position having the sameconcentration level 6 (in the present case, four). Because the former issmaller than the latter in the present case, the remainder will beassigned according to the following steps by taking surroundingpositions into account. First, an average surrounding concentrationlevel is calculated (step P9). The average surrounding concentrationlevel is defined as an average of the concentration levels of thepositions which surround each position having the same concentrationlevel. The average surrounding level is calculated from theconcentration levels shown in FIG. 3, and is expressed with acombination of the central position and the average surrounding level asfollows: "2"-5, "6"-6, "10"-6 and "14"-5. Next, it is decided whetherthe central positions having the same average surrounding level exist(step P10). In the present case, two positions "6" and "10" have thesame average surrounding level. In such a case, the remainder of thepositions to be printed cannot be assigned. Then, the remainder isassigned according to a predetermined priority order. In thisembodiment, the priority order is set as follows: "1", "11", "3", "9","6", "16", "8", "14", "2", "12", "4", "10", "5", "15", "7" and "13".This is the same order as the increasing order of the threshold valuesof the dither matrix of the Bayer type shown in FIG. 1. In the priorityorder, the position "6" is prior to the position "10". Therefore, thelast position to be assigned is decided to be the position "6" (stepP11). Next, the dot position 6 is designated as black (step P12). (Ifthe positions can be determined only by the concentration levels (stepsP7 and P8), the process is skipped to step P12 directly, and thepositions for black dots are designated.)

Next, it is decided whether all the dot positions are designated (stepP13). In this case, all the dot positions are already determined.

Then, it is decided whether all the submatrices are processed or not(step P14). After all the matrices are processed similarly, the bi-leveldata obtained are transmitted to an external equipment (step P15).

The coding of the half-tone image 2 (FIG. 5) is explained similarly inthe following description. (In FIG. 5, the number of dots in eachelement is drawn, for convenience, so as to coincide with the value ofthe concentration level in the counterpart of the picture elements shownin FIG. 6.)

First, the concentration level signals sampled with the image sensor 11are stored in the memory 13 (step Pl).

After all of image 2 has been sampled, the concentration level signalsare processed for a bi-level quantization as follows. Concentrations inthe unit of a 4×4 submatrix shown in FIG. 6, which corresponds to thehalf-tone image 2 shown in FIG. 5, is read out of the memory 13 (stepP2). An average concentration of the concentration pattern is calculated(step P3), and it is found to be 11.6. Next, the dot number isdetermined from the average concentration (step P4). It is determined tobe eleven by cutting off the fraction of the average. (In case ofwhite-dot output, it is determined to be five.)

Next, the concentration level data are arranged in the order of theconcentration by sorting them (step P5). Similarly to the case of theline image 1, the concentration level data are indicated with thecombination of "picture element position"-concentration level. Then, theconcentration level data shown in FIG. 6 are arranged in the order of"4"-14, "8"-14, "11"-14, "12"-14, "15"-14, "16"-14, "7"-13, "10"-13,"14"-13, "13"-12, "3"-11, "6"-11, "9"-11, "5"-11, "5"-4, "2"-3 and"1"-2. (In case of white-dot output the order will be reversed.)

Next, black dots of the dot number determined will be assigned in thedecreasing order of the concentration level. Picture element positionsare decided to be printed or not in the order of the concentrationlevel. First, the concentration level 14 is designated (step P6). It isfound that six positions ("4", "8", "11", "12", "15" and "16") exist atthe same concentration level "14".

A check is made to determine whether the number 6 of the pictureelements at the same concentration level is larger than 1 (step P7). Ifthe check is "Yes" as in this case, it is checked next whether theremainder (in the present case, eleven) still that remain to be assignedis smaller than the number of the positions at the same concentrationlevel (in the present case, six) (step P8). Because the decision is "No"in the present case, we proceed to step P12 and the six positions forblack dots are assigned. Then, it is decided whether the designation ofblack dots up to the dot number is completed (step P13). Because thedecision is "No" in this case, the process is returned to step P6, andthere is designated the next concentration level 13.

Three positions ("7", "10" and "14") having the concentration level "13"and one position ("13") having the concentration level "12" are assignedsimilarly.

After returning again to step P6, it is decided that three positions("3", "6" and "9") exist at the concentration level 11 (step P7). Next,it is checked whether the remainder of the dot number (in the presentcase, one) is smaller than the number (three) of the positions at thesame concentration level 11 (step P8). Because it is checked to be "Yes"in this case, the remainder of print positions will be assigned in thefollowing steps by taking the surrounding concentration into account.First, an average surrounding level is calculated (step P9). We canexpress the average surrounding levels in pairs of the position and theaverage surrounding level as follows: "3"-11.0, "6"-9.125 and "9"-10.6,Then, the position "3" is assigned as the remainder of dot position(step P10). FIG. 13 shows a reproduction thus obtained.

After dot positions are all designated (step P13), the bi-level datathus obtained are transmitted to the memory 13, and then we proceed to anext submatrix (step P14). After all the submatrices are processedsimilarly, the data is transmitted to external equipment (step P15).

In step P9, a sum of the concentrations around the picture element underconsideration can be used instead of the average concentration.

If we compare a reproduction (FIG. 12) of the line image 1 (shown inFIG. 2) according to the present invention with that according to aprior art dither process (FIG. 4), the former has a higher resolutionthan the latter, and reproduces the concentration more faithfully to theoriginal picture. If we compare a reproduction (FIG. 13) of thehalf-tone image 2 (shown in FIG. 5) according to the present inventionwith that according to a prior-art dither process (FIG. 7), the formerreproduces the concentration more faithfully to the original picture andhas a higher resolution than the latter.

This invention may be practiced or embodied in still other ways withoutdeparting from the spirit or essential character thereof. The preferredembodiments described herein are therefore illustrative and notrestrictive, the scope of the invention including variations which comewithin the meaning of the claims are intended to be embraced therein.

What is claimed as new:
 1. A method of image processing for sampling the concentration of each portion of an image divided into a unit of picture elements and for binarizing the concentrations of the picture elements in the unit into submatrices of predetermined size to obtain a bi-level image, being characterized in that the bi-level image is obtained from concentrations that have been sampled according to the steps as follows:(a) calculating the average of the concentrations of the picture elements at every submatrix to which the picture elements belong; (b) determining the number of picture elements in the submatrix to be treated as either one of black or white according to the calculated average; (c) assigning the picture elements in the submatrix to be treated as either one of black or white up to the number determined in the step (b) in order of concentration of each picture element in the submatrix; (d) deciding, during the prosecution of the step (c), whether the total number of elements that still remain to be assigned is smaller than the number of the elements having a similar concentration to be assigned next, and (e) assigning the elements to be assigned next in accordance with a predetermined concentration, which is calculated as either a sum or an average of concentrations of the elements surrounding each element having the same concentration when the number of elements that remain to be assigned is smaller than the elements that would be assigned next.
 2. A method of image processing according to claim 1, wherein said processing of the concentrations comprises the further step of:(f) assigning the elements to be assigned next, in the order of a predetermined table defining the order of assignment in a submatrix, in the case where the surrounding concentrations calculated in the step (e) are equal to each other and therefore, it is impossible to assign elements in the order of surrounding concentration. 